Skip to content

Return exit code 0 when a core is already up to date #2207

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

alessio-perugini
Copy link
Contributor

@alessio-perugini alessio-perugini commented Jun 9, 2023

Please check if the PR fulfills these requirements

See how to contribute

  • The PR has no duplicates (please search among the Pull Requests
    before creating one)
  • The PR follows
    our contributing guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • UPGRADING.md has been updated with a migration guide (for breaking changes)
  • configuration.schema.json updated if new parameters are added.

What kind of change does this PR introduce?

Return exit code 0 if a platform is already at the latest version

What is the current behavior?

Returns exit code 1.

What is the new behavior?

Returns exit code 0.

Does this PR introduce a breaking change, and is titled accordingly?

Other information

@alessio-perugini alessio-perugini linked an issue Jun 9, 2023 that may be closed by this pull request
3 tasks
@alessio-perugini alessio-perugini self-assigned this Jun 9, 2023
@alessio-perugini alessio-perugini added the type: imperfection Perceived defect in any part of project label Jun 9, 2023
@alessio-perugini alessio-perugini added this to the Arduino CLI 0.34.0 milestone Jun 9, 2023
@alessio-perugini alessio-perugini requested a review from cmaglie June 9, 2023 14:36
@codecov
Copy link

codecov bot commented Jun 9, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -0.06 ⚠️

Comparison is base (5725c02) 62.98% compared to head (537807b) 62.93%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2207      +/-   ##
==========================================
- Coverage   62.98%   62.93%   -0.06%     
==========================================
  Files         218      218              
  Lines       19466    19472       +6     
==========================================
- Hits        12261    12254       -7     
- Misses       6122     6137      +15     
+ Partials     1083     1081       -2     
Flag Coverage Δ
unit 62.93% <100.00%> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
internal/cli/core/upgrade.go 81.57% <100.00%> (+4.43%) ⬆️

... and 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@per1234 per1234 added topic: code Related to content of the project itself topic: CLI Related to the command line interface labels Jun 12, 2023
@alessio-perugini alessio-perugini force-pushed the 2086-improve-the-message-printed-when-a-core-is-already-up-to-date branch 3 times, most recently from 874a381 to 17a7f3f Compare June 14, 2023 07:39
@alessio-perugini alessio-perugini force-pushed the 2086-improve-the-message-printed-when-a-core-is-already-up-to-date branch from 17a7f3f to 27f9b05 Compare June 14, 2023 07:59
…de might be wrapped

errors.As search through all the wrapped error for our target type, in case it finds it then it popolate that struct but more important we can use it as a type assertion even if is nested through many errors
@alessio-perugini alessio-perugini merged commit 1877431 into master Jun 15, 2023
@alessio-perugini alessio-perugini deleted the 2086-improve-the-message-printed-when-a-core-is-already-up-to-date branch June 15, 2023 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: CLI Related to the command line interface topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve the message printed when a core is already up-to-date
3 participants